import request from "@/utils/request.js";
//获取商品分类
export function postGoodsType(data) {
	return request.post("goods/type/getPage", data);
}
//通过分类获取商品
export function postGoodsPage(data) {
	return request.post("goods/getPage", data);
}
// 获取商学院分类，固定获取第一页99条记录
export function postVideoClass() {
	let url = `business_school_video_classification/getPage?pageNum=1&pageSize=99`;
	return request.post(url);
}
//通过商学院分类获取商学院内容
export function postVideo(pageNum, pageSize, data) {
	let url =
		`business_school_video/getPage?pageNum=${encodeURIComponent(pageNum)}&pageSize=${encodeURIComponent(pageSize)}`;
	const body = {
		classifyId: data.classifyId
	};
	return request.post(url, body);
}
//通过商学院id获取商学院详情
export function postAgentInformationById(id) {
	const requestUrl = `business_school_video/getById/${encodeURIComponent(id)}`;
	return request.get(requestUrl);
}

//推广人绑定
export function postLogSave(data) {
	return request.post("xing/log/save", data);
}
// export function getAdminOrderDelivery(id) {
//   return request.get(
//     "goods/getById/" + id,
//   );
// }